Regulation of artificial intelligence